#import "AutophonePlugin.h"
#import <TXLoginoauthSDK/TXLoginOauthSDK.h>


@implementation AutophonePlugin
+ (void)registerWithRegistrar:(NSObject<FlutterPluginRegistrar>*)registrar {
  FlutterMethodChannel* channel = [FlutterMethodChannel
      methodChannelWithName:@"autophone"
            binaryMessenger:[registrar messenger]];
  AutophonePlugin* instance = [[AutophonePlugin alloc] init];
  [registrar addMethodCallDelegate:instance channel:channel];
}

- (void)handleMethodCall:(FlutterMethodCall*)call result:(FlutterResult)result {
  if ([@"phoneAuto" isEqualToString:call.method]) {
      [TXLoginOauthSDK initLoginWithId:@"xx"];
      result(@"返回");
  } else {
    result(FlutterMethodNotImplemented);
  }
}

@end
